package com.loop;

/**
 * 在编译时异常的情况下
 *  子类方法的异常类型必须小于等于父类的异常类型
 */
public class MainPoints {
    public static void main(String[] args) {
        Zi zi = new Zi();
        zi.test();
    }
}

class Fu{
    public void test() throws Exception{
        System.out.println(1/0);
    }
}

class Zi extends Fu{
    @Override
    public void test() throws RuntimeException{
        System.out.println(1/1);
    }

}
